import request from '@/utils/request'

// 查询库位管理列表
export function listWarehouseinfoKuwei(query) {
  return request({
    url: '/base/warehouseinfoKuwei/list',
    method: 'get',
    params: query
  })
}
export function listWarehouseinfoKuweiAll() {
  return request({
    url: '/base/warehouseinfoKuwei/listAll',
    method: 'get',
  })
}

// 查询库位管理详细
export function getWarehouseinfoKuwei(id) {
  return request({
    url: '/base/warehouseinfoKuwei/' + id,
    method: 'get'
  })
}
export function getWarehouseTree(id) {
  return request({
    url: '/base/warehouseinfoKuwei/getWarehouseTree',
    method: 'get'
  })
}
export function getListWarehouseinfoKuQu(stockCode) {
  return request({
    url: '/base/warehouseinfoKuwei/getListWarehouseinfoKuQu/'+stockCode,
    method: 'get'
  })
}
export function getListWarehouseinfoKuWei(kuquCode) {
  return request({
    url: '/base/warehouseinfoKuwei/getListWarehouseinfoKuWei/'+kuquCode,
    method: 'get'
  })
}

// 新增库位管理
export function addWarehouseinfoKuwei(data) {
  return request({
    url: '/base/warehouseinfoKuwei',
    method: 'post',
    data: data
  })
}

// 修改库位管理
export function updateWarehouseinfoKuwei(data) {
  return request({
    url: '/base/warehouseinfoKuwei',
    method: 'put',
    data: data
  })
}

// 删除库位管理
export function delWarehouseinfoKuwei(id) {
  return request({
    url: '/base/warehouseinfoKuwei/' + id,
    method: 'delete'
  })
}
